package com.eugene.util;

public class TimeElapse {
	private String testName;
	private long elpaseTime;
	private long baseTime;
	
	
	public TimeElapse (){
		this.elpaseTime =0;
		this.baseTime = System.currentTimeMillis();
	}
	public TimeElapse(String testName){
		this.testName = testName;
		this.elpaseTime =0;
		this.baseTime = System.currentTimeMillis();
	}
	
	public String getTestName() {
		return testName;
	}
	public void setTestName(String testName) {
		this.testName = testName;
	}
	public long getElpaseTime() {
		return elpaseTime;
	}
	public void setElpaseTime(long elpaseTime) {
		this.elpaseTime = elpaseTime;
	}
	public void start(){
		this.baseTime = System.currentTimeMillis();
	}
	public void pause(){
		this.elpaseTime = elpaseTime+ System.currentTimeMillis()- baseTime ;
		this.baseTime = System.currentTimeMillis();
	}
	public void resume(){
		this.baseTime = System.currentTimeMillis();
	}


}
